# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=ghostpack
pkgver=123.20a5f0a
pkgrel=1
pkgdesc='Compiled Binaries for Ghostpack (.NET v4.8.1).'
arch=('any')
groups=('blackarch' 'blackarch-windows')
url='https://github.com/r3motecontrol/Ghostpack-CompiledBinaries'
license=('BSD3-Clause')
depends=()
makedepends=('git')
source=("$pkgname::git+https://github.com/r3motecontrol/Ghostpack-CompiledBinaries.git")
sha512sums=('SKIP')

pkgver() {
  cd $pkgname

  ( set -o pipefail
    git describe --long --tags --abbrev=7 2>/dev/null |
      sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
    printf "%s.%s" "$(git rev-list --count HEAD)" \
      "$(git rev-parse --short=7 HEAD)"
  )
}

package() {
  cd "$pkgname/dotnet v4.8.1 compiled binaries"

  install -dm 755 "$pkgdir/usr/share/windows/$pkgname"

  cp -a * "$pkgdir/usr/share/windows/$pkgname/"
}

